Skip to content

Added handling of SELECT @@version and SELECT VERSION() without backend #4889

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: v3.0
Choose a base branch
from

Conversation

yashwantsahu20
Copy link
Contributor

@yashwantsahu20 yashwantsahu20 commented Mar 27, 2025

Added handling of SELECT @@Version and SELECT VERSION() without backend.

Currently returning server version as 8.0.0, but may be we should get it from global variables.
Tested it manually.

This change is related to aaiomysql third-party testing.

mysql> select @@Version;
+------------------+
| select @@Version |
+------------------+
| 8.0.0 |
+------------------+
1 row in set (4.77 sec)

mysql> SELECT VERSION();
+------------------+
| SELECT VERSION() |
+------------------+
| 8.0.0 |
+------------------+
1 row in set (2.77 sec)

For detail:
https://github.com/ProxySQL/proxysql_3p_testing/issues/18

@renecannao
Copy link
Contributor

Initial requirement:

Reply to client’s queries SELECT @@version (and also lowercase) returning the value of mysql-server_version without the need of any backend. For reference, we already have a similar implementation for SELECT LAST_INSERT_ID() . The query should also not disable multiplexing. TAP test for this can be temporarily skipped.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants